package android.tusnotas.beans;

import android.os.Parcel;
import android.os.Parcelable;

public class GroupFile implements Parcelable{
	
	private String name;
	private String link;
	private String extension;
	private long size;
	private String date;
	private String uploaderName;
	
	public GroupFile(String name, String link, String extension, long size,
			String date, String uploaderName) {
		super();
		this.name = name;
		this.link = link;
		this.extension = extension;
		this.size = size;
		this.date = date;
		this.uploaderName = uploaderName;
	}

	public GroupFile() {
		super();
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getLink() {
		return link;
	}

	public void setLink(String link) {
		this.link = link;
	}

	public String getExtension() {
		return extension;
	}

	public void setExtension(String extension) {
		this.extension = extension;
	}

	public long getSize() {
		return size;
	}

	public void setSize(long size) {
		this.size = size;
	}

	public String getDate() {
		return date;
	}

	public void setDate(String date) {
		this.date = date;
	}

	public String getUploaderName() {
		return uploaderName;
	}

	public void setUploaderName(String uploaderName) {
		this.uploaderName = uploaderName;
	}

	@Override
	public int describeContents() {
		return hashCode();
	}
	
	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeString(this.name);
		dest.writeString(this.link);
		dest.writeString(this.extension);
		dest.writeLong(this.size);
		dest.writeString(this.date);
		dest.writeString(this.uploaderName);
	}

	private GroupFile(Parcel in){
		this.name=in.readString();
		this.link=in.readString();
		this.extension=in.readString();
		this.size=in.readLong();
		this.date=in.readString();
		this.uploaderName=in.readString();
	}

	public static final Parcelable.Creator<GroupFile> CREATOR = new Parcelable.Creator<GroupFile>() {
		public GroupFile createFromParcel(Parcel in) {
			return new GroupFile(in);
		}

		public GroupFile[] newArray(int size) {
			return new GroupFile[size];
		}
	};


}
